package org.jeecg.modules.demo3.peijian.utill;

import java.io.File;

/**
 * @author wjn
 * @version V1.0
 * @date 2021/5/6 17:08
 * @Copyright © 2021/5/6 深圳卓翼航空无人机有限公司
 */
//根据文件路劲删指定文件
public class DeleteFile {

    public int deleteFile(String pathName){
        int i = 0;
        try {
            String filePath = pathName.toString();
            File file = new File(filePath);
            file.delete();
            i = 1;
        }catch (Exception e){
            i = 0;
            e.printStackTrace();
        }
        return i;
    }
}
